Method for controlling the execution of a program configurable into a disabled state and enabled state

ABSTRACT

The invention deals a method for controlling the execution of a program by a terminal (1) comprising a screen (12), wherein the method comprises the steps of: configuring the program into an enabled state, wherein at least one process of the program is allowed to be executed by the terminal (1), and a disabled state, wherein execution of any process of the program by the terminal (1) is forbidden, wherein the method further comprises the steps of: displaying (100) on the screen (12) an icon (G) for starting the program according to a first rendering if the program is configured in the enabled state, and displaying (114) said icon (G) according to a second rendering different from the first rendering if the program is configured in the disabled state.

TECHNICAL FIELD

The invention deals with a method for controlling the execution of aprogram configurable into an enabled state and a disabled state.

STATE OF THE ART

Most applications installed in a terminal comprise different types ofprocesses or services: foreground processes interacting with a user ofthe terminal through a graphical user interface, and backgroundprocesses.

An application can typically started when a user of the terminal clickson or taps on an icon of the application displayed on a screen of theterminal. This icon is commonly displayed in a specific menu showingicons of all applications installed in the terminal. This icon can alsobe displayed in a default menu displayed in the first place whenever theuser turns on the screen of the terminal and commonly referred to as“home screen”.

However, a background process may be secretly running even though theuser is not currently using the application. A background process can bestarted whenever an operating system of the terminal is booted, or upondetecting some other device events. Such a background process canperform actions on the device by checking the device location, the appupdates or news from the internet which secretly consumes the terminalresources such as CPU, memory, consequently the battery and so on.

To block out any activities issued from an installed application for aperiod of time, the user could choose to uninstall the wholeapplication, and reinstall it whenever needed afterwards.

However, re-installing an application requires downloading it from aremote server.

Some existing operating systems allow the user to “disable” apre-installed application. The operating system configures alternatelythe application into an enabled state, wherein at least one process ofthe program is allowed to be executed, and a disabled state, whereinexecution of any process of the program is forbidden.

Disabling an application, i.e. configuring the application in itsdisabled state, is performed by clicking on a graphical button displayedin a dedicated settings menu of the operating system. After disabling,all icons of the application are removed from the home menu and from theapplication menu.

As a consequence, in order to launch a disabled application, the userhas to find, and enable the application from the settings menu, then goback to the home screen to launch it. It is not a simple and intuitiveway for a user who'd like to temporally disable and enable anyapplication installed on the device quickly.

Besides, the user has to access the settings menu is order to clearlyknow if an application is enabled or disabled.

SUMMARY OF THE INVENTION

The invention aims at warning the user that an application is currentlyenabled or disabled in a simpler way than the prior art.

For this purpose, the invention proposes a method for controlling theexecution of a program by a terminal comprising a screen, wherein themethod comprises the steps of: configuring the program into an enabledstate, wherein at least one process of the program is allowed to beexecuted by the terminal, and a disabled state, wherein execution of anyprocess of the program by the terminal is forbidden, wherein the methodfurther comprises the steps of: displaying on the screen an icon forstarting the program according to a first rendering if the program isconfigured in the enabled state, and displaying said icon according to asecond rendering different from the first rendering if the program isconfigured in the disabled state.

The process may further comprise the following features taken separatelyor combined whenever it is technically possible:

-   -   rendering the icon using a first set of colors if the current        state is the enabled state, and rendering the icon is rendered        using a second set of colors if the current state is the        disabled state, wherein the second set of colors is a subset of        the first set;    -   altering a default shape of the icon into a first altered shape        if the current state is one of the disabled and enabled states,        and altering a default shape of the icon into a second altered        shape or leaving said default shape unchanged, if the current        state is the other state;    -   compositing the icon with a first indicator overlapping the        icon, if the current state is one of the disabled and enabled        states, and compositing the icon with a second indicator        overlapping the icon, wherein the second indicator is different        from the first indicator, or leaving the icon free of indicator,        if the current state is the other of the two states:    -   configuring the program into the enabled state whenever        detecting that the program has been started using the icon;    -   displaying a context menu whenever detecting that the icon was        pressed on or tapped on, said menu showing a first item for        directly starting the application and another item for changing        the state of the program;    -   detecting a user event indicating that the icon has been moved        on the screen according to a first predetermined motion pattern,        and changing the current state of the program in response to        detecting the user event;    -   using as a predetermined motion pattern a motion of the icon        into a predetermined area of the screen;    -   detecting that the icon has been dragged and dropped in the        predetermined area as user event;    -   displaying a target indicating the location of the predetermined        area on the screen    -   displaying the target whenever detecting that the icon has been        pressed on during a predetermined duration, and erasing the        target from the screen in response to detecting the user event;    -   detecting a second user event ordering to stop the program after        it has been started, and configuring the application into the        disabled state in response to detecting the second user event;    -   terminating, ending and/or killing any process of the program        being executed whenever the program is configured into the        disabled state;    -   saving the state the program has been configured into a        non-volatile memory of the terminal;    -   configuring the program so that metadata of the program stored        in a memory of the terminal is still accessible when said        program is in the disabled state.

The invention also proposes a computer program product comprising codeinstructions for execution of the method for controlling the executionof a program by a terminal.

The invention also proposes a terminal comprising a screen, a memorystoring a computer program, at least one processor for executing theprogram, said processor being configured to configure alternately theprogram into an enabled state, wherein at least one process of theprogram is allowed to be executed by the processor, and a disabledstate, wherein execution of any process of the program by the processoris forbidden, wherein the terminal is characterized in that theprocessor is further configured to display on the screen an icon forstarting the program according to a first rendering if the program isconfigured in the enabled state, and display said icon according to asecond rendering different from the first rendering if the program isconfigured in the disabled state.

DESCRIPTION OF FIGURES

Further features, goals and advantages will be highlighted in thefollowing description which is not limitative and must be read inrelation with the following figures.

FIG. 1 represents schematically a terminal according to an embodiment ofthe invention.

FIG. 2 represents steps of a method for controlling execution of acomputer program by a terminal, according to an embodiment of theinvention.

FIGS. 2 and 3 represent steps of a method for controlling execution of acomputer program by a terminal according to an embodiment of theinvention.

FIGS. 4a to 4d represent different states of a terminal while the stepsof FIG. 3 are carried out.

FIG. 5 represent other steps of a method for controlling execution of acomputer program by a terminal according to an embodiment of theinvention.

FIGS. 6a to 6c represent different states of a terminal while the stepsof FIG. 5 are carried out.

On all figures, similar elements have identical references.

DETAILED DESCRIPTION OF AN EMBODIMENT OF THE INVENTION

Referring to FIG. 1, a terminal comprises at least one processor 10, ascreen 12, a user input interface 14 and a memory 16.

The memory 16 comprises a volatile memory unit 18 (such as RAM) and anon-volatile memory unit 20 (such as flash memory, HDD memory, SSDmemory of a combination thereof).

The user input interface 14 typically is configured to capture userevents: it may comprise a keyboard, a touchscreen 12, a mouse, or acombination thereof.

An operating system is stored in the non-volatile memory unit 20, aswell as at least one computer program referred to as an “application” inthe following.

The processor 10 is configured to execute the operating system and theapplication.

The operating system is configured to control the execution of theapplication by the processor 10.

The operating system comprises instructions for displaying a graphicaluser interface (GUI) on the screen 12 of the terminal 1. This GUItypically comprises a “home screen” menu, an application menu and asettings menu known of the prior art and discussed in the introduction.

The application is associated with graphical data for displaying on thescreen 12 an icon G (illustrated on FIGS. 4a-4d and 6a-6c ) for startingthe application.

The operating system is further configured to start the application oncea particular user event involving the icon G is detected. This userevent will be described later on.

The application comprises at least one foreground process comprisingcode instructions for displaying a GUI specific to this application andfor communicating with the user input interface 14 through the operatingsystem.

The application further comprises at least one background process. Asindicated before, the background process may be executed by theprocessor secretly, even though the user has closed the application.

The application may be configured by the operating system into twodifferent states:

-   -   an enabled state, wherein at least one process of the program is        allowed to be executed by the operating system, and    -   a disabled state, wherein execution of any process of the        program by the operating system is forbidden.

More particularly, the background process shall not be executed by theterminal 1 if the application is disabled.

In practice, a flag may identify the current state of an application: inthe disabled state, the flag is set to a first value (say 0) and in theenabled state the flag is set to a second value different from the firstvalue (say 1).

This flag can be saved in the non-volatile memory unit and updatedwhenever the state changes.

The operating system may secretly start any background process of anenabled application, i.e. without the user's explicit demand.

An enabled application may be automatically started when the operationsystem boots up. For instance, Windows operating system startsautomatically an application at boot if said application is linked to a“startup” folder, has a service registered in the OS, or is in somewherein the Windows Registry. Android operating system also offers such afeature by automatically invoking an enabled application once the deviceboot is completed.

The operating system can also start and/or run a process of an enabledprogram secretly whenever the user unlocks the terminal, i.e. aftersuccessful authentication of the user (using a PIN code, a gesture drawnon screen, etc.).

On the contrary, the operation system refrains from starting and runningany process of a disabled application, including background processes.

In an embodiment, the operating system is authorized to access (read)metadata stored in the memory 16 (typically the non-volatile memory 20)that is specifically associated with a disabled program.

This metadata may include assets such as image data (especially icons),audio data, video data and/or text data (such as the program's manifestfile).

Disabling an Enabled Application

The application is first supposed to be enabled, i.e. its state issupposed to be set to the value “enabled”.

Referring to FIG. 2, the operating system displays the icon G of theapplication on the screen 12 according to a first rendering R1 in a step100 (see FIG. 4a ).

This first rendering R1 is for instance a default rendering of thegraphical data using a predetermined set of colors.

This first rendering R1 can also comprise a first shape alteration ofthe default shape of the icon.

This first rendering R1 can comprise a first composition of the iconwith a first indicator overlapping the icon.

This step 100 occurs when the user accesses a menu containing the iconG, such as the applications menu or the home screen H.

In a step 102, the operating system detects a predetermined user eventindicating that the icon G has been moved on the screen 12 according toa first predetermined motion pattern.

In an embodiment the detection step 102 comprises the sub-stepsillustrated on FIG. 3 and the terminal 1 behaves as illustrated on FIGS.4a -4 d.

In this embodiment, the motion pattern is a motion of the icon G into apredetermined area A of the screen 12, for example a rectangular toppart of the screen 12 of predetermined size.

In a sub-step 200, the operating system detects that the user presses onthe icon G for a predetermined duration.

In response to said detection 200, the operating system displays 202 atarget T indicating the location of the predetermined area A (see FIG.4a ).

Besides, the operation system checks the current state of theapplication and displays as target T a piece of text corresponding tothe action of switching the state of the application from the currentstate into the other state. For instance, the word “disable” isdisplayed in the target T (see FIG. 4b ).

Whenever the operation system detects that 204 the icon G has beendragged then dropped in the predetermined area A of the screen 12,disabling 104 or enabling 118 the application is triggered.

The target T is erased from the screen 12 when the user “drops” the iconG, i.e. when the operating system detects that the user stops pressingthe icon G after dragging it (see FIGS. 4c and 4d ).Now turning back toFIG. 2, the operating system reconfigures 104 the applications in the“disabled” state in response to detecting 102 the user event. Thisreconfiguration makes sure that the operation system refrains fromstarting and running any background process of the application.

The operating system further checks if any process of the application iscurrently run by the processor 10. If yes, the operating systemsterminates, ends and/or kills any running process of the application ina step 106. The space allocated in the volatile memory by these runningprocesses is also freed.

Besides, the flag associated with the application is set 108 to the“disabled” value and saved 110 in the non-volatile memory of theterminal 1. As a consequence, the application will still be disabledeven if the terminal 1 is turned off then turned on again and/or if theoperation system reboots for some reason.

In a step 112, the operating system displays the icon G of theapplication according to a second rendering R2 different from the firstrendering R1 (see FIG. 4d ).

For instance, the second rendering R2 uses a limited set of colors,which is a subset of the set of colors used for the first rendering R1.In an embodiment, the icon G is displayed according to the secondrendering in monochrome or in grayscale.

The second rendering R2 can also be a second shape alteration of theicon wherein the second shape alteration is different from the firstshape alteration of rendering R1.

It should be understood that one of the two renderings R1 et R2 may notperform any alteration of the icon while the other rendering does.

Alternatively, this first rendering R1 can be a composition of the iconwith a second indicator overlapping the icon that is different from thefirst indicator using in rendering R1.

Reconfiguration 104, termination 106, update 108 and displaying step 112may be carried out in any order after detecting 102 the user eventindicating that the icon G was moved according to the predeterminedmotion pattern.

Enabling a Disabled Application

Referring to FIG. 5, the application is switched from the “disabled”state to the “enabled” state according to the following steps.

We suppose that the icon G is displayed 114 according to the secondrendering R2 (see FIG. 6a ).

In step 116, the operation system detects that the user clicked on ortapped on the icon G of the disabled application.

In response to this detection 116, the operation also reconfigures 118the application into the “enabled” state. Once the configuration 118 iscomplete, background processes are allowed to be run by the processor10.

Besides, the operating system automatically starts 120 the application.

This automatic startup of the application is advantageous in that theuser needs not access any settings menu in order to re-enable theapplication before starting it. In other words, enabling and launchingan application are merged into one single user action.

At startup, a foreground process of the application is executed by theprocessor 10, which displays the GUI M of the application on the screen12 (see FIG. 6b ).

Besides, the flag associated with the application is set 122 to the“enabled” value and saved 122 in the non-volatile memory of the terminal1. As a consequence, the application will still be enabled even if theterminal 1 is turned off then turned on again and/or if the operationsystem reboots for some reason.

Besides, the operating system displays the icon G of the application onthe screen 12 according to a first rendering R1 in the step 100 (seeFIG. 6c ) in response to this detection 116.

This change may not be immediately visible on the screen 12 if the GUI Mof the application actually covers the icon G. But this change will bevisible on the screen once the user exits the application, for instanceby clicking on the cross X illustrated on FIG. 6 b.

In another embodiment, the application is not directly started wheneverthe user clicks on or taps on the icon G. The operation system ratherdisplays a context menu whenever detecting that the icon G was pressedon or tapped on.

The context menu shows a first graphical item for directly starting theapplication, and a second graphical item for changing the state of theprogram.

If the operating system detects that the user clicks on or taps on thesecond item, the operation system reconfigures the application into the“enabled” state but the application is not directly started. From thispoint on, the operation system is allowed to start a background processof the application secretly.

If the operating system detects that the user clicks on or taps on thefirst item, the operation system starts the application and temporarilyallows processes of said application to be run until the user exits theapplication.

If the operating system detects that the user clicks or taps outside thecontext menu, which does not displayed full screen 12, the operatingsystems closes the context menu.

The operating system may also enable a disabled application wheneverthat the icon G has been moved on the screen 12 according to a secondpredetermined motion pattern.

This second motion pattern may be identical to the first motion pattern;in this case, all steps 200, 202, 204, 206 can be performed as well forenabling an application (but text “enable” is displayed in target Tinstead of text “disable”).

The method described upwards for controlling the execution of anapplication in the terminal 1 can be performed for each applicationinstalled in the terminal 1. Each application has its own state, its ownicon, and can therefore be enabled and disabled independently of theother applications.

In an embodiment, a set of applications may be disabled or enabled byperforming the drag-and-drop procedure of FIG. 3 on a folder containingicons of each application in said set of applications, rather than on asingle icon G.

Another context in which the icon G of a program may be displayed iswhenever a user of the terminal 1 is invited to select a program among apredetermined set of programs in response to a particular action.

Such an action is for example clicking on a “share” button printed on aweb page or on the GUI of another program that is being displayed on thescreen of the terminal 1. The predetermined set of programs comprises inthis case all programs installed in the terminal 1 and implementing afunction of sharing content over a network such as the Internet (mailingapplications, social network clients and so on).

In response to clicking on the “share” button, the operating systemdisplays on the screen all icons of said predetermined programs as alist.

Each icon is rendered using rendering R1 or R2, depending on the currentstate of each program.

Whenever the user clicks on or taps on an icon that is displayedaccording to rendering R2 (meaning that the corresponding application isin the “disabled” state), all steps 116, 118, 120 are performed.

A disabled application may also be enabled using other triggers thatdetection 116 involving the icon G, for instance whenever detecting thatthe user did a predetermined gesture on the touchscreen (i.e drew aparticular pattern), said predetermined gesture being associated withthe program.

Besides, it should be understood that all steps described above thatinvolve the icon G of the program may be performed for all short-cuticons of said program scattered in different menus of the operatingsystem (or the same menu).

More particularly, disabling or enabling a program triggers a change ofrendering R1 or R2 of all icons of said program used by the user asshort-cuts.

1. Method for controlling the execution of a program by a terminal (1)comprising a screen (12), wherein the method comprises the steps of:configuring the program into: an enabled state, wherein at least oneprocess of the program is allowed to be executed by the terminal (1),and a disabled state, wherein execution of any process of the program bythe terminal (1) is forbidden, wherein the method further comprises thesteps of: displaying (100) on the screen (12) an icon (G) for startingthe program according to a first rendering if the program is configuredin the enabled state, displaying (114) said icon (G) according to asecond rendering different from the first rendering if the program isconfigured in the disabled state.
 2. Method as claimed in claim 1,comprising the steps of: rendering the icon (G) using a first set ofcolors if the current state is the enabled state, rendering the icon (G)is rendered using a second set of colors if the current state is thedisabled state, wherein the second set of colors is a subset of thefirst set.
 3. Method as claimed in claim 1, comprising: altering adefault shape of the icon into a first altered shape if the currentstate is one of the disabled and enabled states, altering a defaultshape of the icon into a second altered shape or leaving said defaultshape unchanged, if the current state is the other state.
 4. Method asclaimed in claim 1, comprising: compositing the icon with a firstindicator overlapping the icon, if the current state is one of thedisabled and enabled states, compositing the icon with a secondindicator overlapping the icon, wherein the second indicator isdifferent from the first indicator, or leaving the icon free ofindicator, if the current state is the other of the two states. 5.Method as claimed in claim 1, comprising the steps of configuring theprogram into the enabled state whenever detecting that the program hasbeen started using the icon (G).
 6. Method as claimed in claim 1,comprising the steps of displaying a context menu whenever detectingthat the icon (G) was pressed on or tapped on, said menu showing a firstitem for directly starting the application and another item for changingthe state of the program.
 7. Method as claims in claim 1, furthercomprising the steps of detecting a user event indicating that the icon(G) has been moved on the screen (12) according to a predeterminedmotion pattern, and changing the current state of the program inresponse to detecting the user event.
 8. Method as claimed in claim 7,wherein the predetermined motion pattern is a motion of the icon (G)into a predetermined area (A) of the screen (12).
 9. Method as claimedin claim 8, wherein the user event indicates that the icon (G) has beendragged and dropped in the predetermined area (A).
 10. Method as claimedin claim 8, further comprising displaying a target (T) indicating thelocation of the predetermined area (A) on the screen (12).
 11. Method asclaimed in claim 10, further comprising: displaying (202) the target (T)whenever detecting that the icon (G) has been pressed on during apredetermined duration, erasing (206) the target from the screen (12) inresponse to detecting the user event.
 12. Method as claimed in claim 7,further comprising: detecting a second user event ordering to stop theprogram after it has been started, configuring the application into thedisabled state in response to detecting the second user event. 13.Method as claimed in claim 1, further comprising terminating, endingand/or killing (106) any process of the program being executed wheneverthe program is configured into the disabled state.
 14. Method as claimedin claim 1, further comprising saving (110, 124) the state the programhas been configured into a non-volatile memory of the terminal (1). 15.Method as claimed in claim 1, wherein metadata of the program that isstored in a memory (20) of the terminal is still accessible when saidprogram is in the disabled state.
 16. Computer program productcomprising code instructions for execution of a method for controllingexecution of a program by a terminal (1) comprising a screen (12), whenthis program product is executed by at least one processor (10), whereinthe method comprises the steps of: configuring the program into: anenabled state, wherein at least one process of the program is allowed tobe executed by the terminal (1), and a disabled state, wherein executionof any process of the program by the terminal (1) is forbidden, whereinthe method further comprises the steps of: displaying (100) on thescreen (12) an icon (G) for starting the program according to a firstrendering if the program is configured in the enabled state, displaying(114) said icon (G) according to a second rendering different from thefirst rendering if the program is configured in the disabled state. 17.Terminal (1) comprising: a screen (12), a memory (16) storing a computerprogram, at least one processor (10) for executing the program, saidprocessor (10) being configured to configure alternately the programinto: an enabled state, wherein at least one process of the program isallowed to be executed by the processor (10), a disabled state, whereinexecution of any process of the program by the processor (10) isforbidden, wherein the terminal (1) is characterized in that theprocessor is further configured to: display on the screen (12) an icon(G) for starting the program according to a first rendering if theprogram is configured in the enabled state, display said icon (G)according to a second rendering different from the first rendering ifthe program is configured in the disabled state.
 18. Method as claimedin claim 9, further comprising displaying a target (T) indicating thelocation of the predetermined area (A) on the screen (12).